<div class="card-head">
    <span class="ft-primary">事件查询</span>

</div>

<div class="card">
    <div class="card-search">
        <div class="row">
            <div class="col-md-2">
                <input type="text" class="form-control" [(ngModel)]="etype" placeholder="请输入事件类型">
            </div>
            <div class="col-md-2">
                <input type="text" class="form-control" [(ngModel)]="action" placeholder="请输入事件行为">
            </div>
            <div class="col-md-8">
                <button type="button" class="exbtn exbtn-primary" (click)="search()">搜索</button>
            </div>
        </div>
    </div>

    <div *ngIf="isNull!=1">
        <div class="row">
            <div class="col-md-4">
                {{pageObj.total}}/{{pageObj.currentPage}}/{{pageObj.numPages}}
            </div>

            <div class="col-md-8">
                <ngb-pagination [(collectionSize)]="pageObj.total" [(page)]="pageObj.currentPage" [(pageSize)]="pageObj.count" [maxSize]="5" [boundaryLinks]="true" (pageChange)="pageChanged()" size="sm"></ngb-pagination>
            </div>
        </div>
        <table class="table  table-hover table-striped">
            <thead>
                <tr>
                    <th width="70px">序号</th>
                    <th>标识</th>
                    <th>类型</th>
                    <th>行为</th>
                    <th>来至</th>
                    <th>时间</th>
                    <th width="170px">操作</th>
                </tr>
            </thead>
            <tbody *ngIf="isNull!=1">

                <tr *ngFor="let item of datas;let i=index;">
                    <td align="center">{{i+1}}</td>
                    <td align="center">{{item.eid}}</td>
                    <td align="center">{{item.etype}}</td>
                    <td align="center">{{item.action}}</td>
                    <td align="center">{{item.from}}</td>
                    <td align="center">{{item.occTime | date:"y-MM-dd HH:mm:ss"}}</td>
                    <td align="center">
                        <button type="button" class="btn btn-sm btn-info" (click)="info(item)">明细</button>
                    </td>
                </tr>

            </tbody>
            <tr *ngIf="isNull==1">
                <td colspan="5" class="text-sm-center">未查询到相关信息</td>
            </tr>

        </table>

    </div>